<?php
defined('BY_JYA') or exit('error');
$list = array(
	array('title'=>'应用工具','list'=>array(
		array('name'=>'jy_supplier','title'=>'供货商','desc'=>'进货ERM,厂家供货','icon'=>'',),
		array('name'=>'jy_supplier_fee','title'=>'供货商招商员','desc'=>'招商进货ERM,厂家供货','icon'=>'',),
		array('name'=>'jy_weishoplive','title'=>'互动直播','desc'=>'主播发红包,券','icon'=>''),
	)),
);
//判断是否基本设置了
$inplugins=array();
$noplugins=array();
foreach($list as $k=>&$type){
		foreach($type['list'] as $i=>&$p){
			$install = check_permission($p['name']);
			$plugin=pdo_get('core_plugins',array('name'=>$p['name']),array('title','image','hide'));
			if($plugin['hide']){
				unset($type['list'][$i]);
			}
			if($install){
				$p['title']=$p['name']!='jy_weishop' && $plugin['title']?$plugin['title']:$p['title'];
				$p['image']=$p['image']?:$plugin['image'];
				$p['is_install'] = 1;
				$p['is_show'] = 1;
			}else{
				$noplugins[]=$p['name'];
				//unset($type['list'][$i]);
				$p['is_install'] = 0;
				$p['is_show'] = 0;
				if($_SESSION['isfounder']){
					$p['is_show'] = 1;
				}
			}
		}
}
return  $list;
?>